/**
 * Order.js
 *
 * @description :: TODO: You might write a short summary of how this model works and what it represents here.
 * @docs        :: http://sailsjs.org/documentation/concepts/models-and-orm/models
 */
const uuid = require('node-uuid');

module.exports = {
  tableName: 'order',
  attributes: {
    id: {
      type: 'string',
      primaryKey: true,
      required: true,
      defaultsTo: function () {
        return uuid.v4();
      }
    },
    card_no: {
      type: 'string'
    },
    title: {
      type: 'string'
    },
    products: {
      type: 'string'
    },
    glass_num: {
      type: 'string'
    },
    left_eye: {
      type: 'string'
    },
    right_eye: {
      type: 'string'
    },
    total: {
      type: 'string'
    },
    point_gain: {
      type: 'string'
    },
    time: {
      type: 'string'
    },
    remark: {
      type: 'string'
    }
  }
};

